#include <ctype.h>
#include <stdio.h>
#include <string.h>

char code(char c)
{
    int secPas;
    int w = c - 5;
    if(w<65){
        w = 90 - (65 - w) + 1;
    }
    secPas = w;
    return (char)secPas;
}

int main(int argc, char *argv[])
{

    
    char begin[5], end[5], paw[201];
    while (1)
    {
        gets(begin);
        gets(paw);
        gets(end);
        int len = strlen(paw);
        if(len==0)
            break;
        for (size_t i = 0; i < len; i++)
        {
            if(isupper(paw[i])){
                printf("%c", code(paw[i]));
            }else{
                printf("%c", paw[i]);
            }
        }
        printf("\n");
        memset(paw, 0, 201);
    }

    return 0;
}